package net.thxjj.adminServer.dao;

import java.util.List;

import net.thxjj.adminServer.entity.aep.DevLog;
import net.thxjj.adminServer.util.ParameterMap;
import org.apache.ibatis.annotations.Param;

public interface DevLogDao {
	//存储数据接口
	public void saveDeviceEvent(List<DevLog> list);
	//存储单个数据接口
	public void saveSingleDevLog(DevLog device_log);

	//获取最新的报警事件数据(根据event_content搜索)
	public DevLog getNewstEvent(@Param("device_id") String device_id,@Param("content") String content);
	public DevLog getNewstEventByTime(@Param("device_id") String device_id,@Param("time") long time,@Param("content") String content);
	public List<DevLog> getEventAtTime(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time,@Param("content") String content);
	public List<DevLog> getFaultDataAtTime(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);
	public List<DevLog> getLowVoltDataAtTime(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);
	public List<DevLog> getDismantleDataAtTime(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);
	public List<DevLog> getDataAtTime(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);

	public DevLog getEarliestEventAtTime(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time,@Param("content") String content);

	//获取最早的报警事件数据(根据event_content搜索)
	public DevLog getEarliestEvent(@Param("device_id") String device_id);

	public List<ParameterMap> getSmokeValueList(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);

	public List<ParameterMap> getBatteryValueList(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);

	public List<Long> getSmokeHappenList(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);

	public Long getSmokeRecoryPoint(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);

	public List<ParameterMap> getSmokeStateHistory(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);

	public List<ParameterMap> getSnrHistory(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);

	public List<ParameterMap> getSignalPowerHistory(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);

	public List<ParameterMap> getTxPowerHistory(@Param("device_id") String device_id,@Param("start_time") long start_time,@Param("end_time") long end_time);

	public List<DevLog> getAllEvent();
}
